﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="zjlist.aspx.cs" Inherits="weikebuluo.web.admin.actives.zjlist" %>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta content="IdeaSoft软件" name="Keywords">
	<meta content="IdeaSoft软件二维码" name="Description">
    <link rel="stylesheet" type="text/css" href="/css/Bootstrap/bootstrap.min.css" />
    <link rel="stylesheet" type="text/css" href="/css/Bootstrap/bootstrap.responsive.min.css" />
    <link rel="stylesheet" type="text/css" href="/css/Bootstrap/style.css" />
    <link rel="stylesheet" type="text/css" href="/css/Bootstrap/todc_bootstrap.css" />
    <link rel="stylesheet" type="text/css" href="/css/Bootstrap/themes.css" />
    <link rel="stylesheet" type="text/css" href="/css/Bootstrap/inside.css" />
    <script type="text/javascript" src="/Scripts/JQuery.min.js"></script>

    <script type="text/javascript" src="/Scripts/JQuery.cookie.js"></script>
    <script type="text/javascript" src="/Scripts/JQuery.form.min.js"></script>
    <script type="text/javascript" src="/Scripts/JQuery.form.wizard.min.js"></script>
    <script type="text/javascript" src="/Scripts/Bootstrap.min.js"></script>
    <script type="text/javascript" src="/Scripts/Inside.js"></script>

<title>会员管理</title>
</head>
<body>
	    <div id="main">
        <div class="container-fluid">
            <div class="row-fluid">
                <div class="span12">

                    <div class="box">
                        <div class="box-title">
                            <div class="span6">
                                <h3><i class="icon-table"></i>会员管理</h3>
                            </div>
                            
                        </div>
                        <div class="box-content nozypadding">
                            <div class="row-fluid">
                                <div class="span6 control-group">
                                    
                                    <a class="btn" href="javascript:location.reload()"><i class="icon-refresh"></i>刷新</a>
                                    
                                </div>
                                <div class="span2">刮奖人数：<%=count%></div>
                            </div>

                            <div class="row-fluid dataTables_wrapper">
                                    <table id="listTable" class="table table-hover table-nomargin table-bordered usertable dataTable">
										
                                    </table>
                                    <div class="dataTables_paginate paging_full_numbers">
                                        <span id="lb_page"></span>
                                    </div>
									<div class="dataTables_paginate paging_full_numbers"><span>       </span></div>
                            </div>
                        </div>
                    </div>
                </div>

            </div>
        </div>
    </div>

    </body>
</html>
<script src="../../../scripts/Su.common.js" type="text/javascript"></script>
<script type="text/javascript">
    var url = "zjlist.aspx";
    var page = 1;
    $(function () {
        GetList();
    })
    function GetList() {
        $.ajax({
            url: url + "?action=list&id="+getQueryString("id"),
            type: "post",
            data: { page: page },
            success: function (msg) {
                var str = '<thead><tr><th>姓名</th><th>卡号</th><th>电话号码</th><th>中奖奖项</th>';
                str += '<th>操作</th></tr></thead>';
                if (msg.replace("[]", "").length > 0) {
                    msg = eval("(" + msg + ")");
                    var total = msg.total;
                    var rows = msg.rows;
                    $(rows).each(function (i) {
                        str += '<tr><td>' + rows[i].vip_name + '</td><td>' + rows[i].vip_code + '</td><td>' + rows[i].vip_phone + '</td><td>' + rows[i].ggklog_award + '</td>';
                        str += '<td></td><tr>';
                    });
                    if (parseInt(total) > (15 * parseInt(page))) {
                        $("#lb_page").html('<a href="#" onClick="GetPage(' + (parseInt(page) + 1) + ')">下一页</a>');
                    } else {
                        $("#lb_page").html('');
                    }
                    if (parseInt(page) > 1) {
                        $("#lb_page").html('<a href="#" onClick="GetPage(' + (parseInt(page) - 1) + ')">上一页</a>' + $("#lb_page").html());
                    }
                }
                $("#listTable").html(str + "</tbady>");
            }
        });
    }
    function GetPage(p) {
        page = p;
        GetList();
    }

</script>
